home *** CD-ROM | disk | FTP | other *** search
/ User's Choice Windows CD / User's Choice Windows CD (CMS Software)(1993).iso / utility2 / wine02bx.zip / LISP / COMINT / KERMIT.ELC < prev    next >
Text File  |  1993-03-28  |  2KB  |  39 lines

  1. ;;; compiled by jwz@thalidomide on Thu Jul  2 14:39:21 1992
  2. ;;; from file /u/jwz/emacs19/lisp/comint/kermit.el
  3. ;;; emacs version 19.2.1 Lucid.
  4. ;;; bytecomp version 2.07; 17-jun-92.
  5. ;;; optimization is on.
  6. ;;; this file uses opcodes which do not exist in Emacs18.
  7.  
  8. (if (and (boundp 'emacs-version)
  9.      (or (and (boundp 'epoch::version) epoch::version)
  10.          (string-lessp emacs-version "19")))
  11.     (error "This file was compiled for Emacs19."))
  12.  
  13. (require 'shell)
  14. (defvar kermit-esc-char "" "\
  15. *Kermit's escape char")
  16. (fset 'kermit-esc #[nil "└┴p!\n├─ !P\"ç" [process-send-string get-buffer-process kermit-esc-char char-to-string read-char] 5 "\
  17. For sending escape sequences to a kermit running in shell mode." nil])
  18. (fset 'kermit-send-char #[nil "└┴p!┬├ !\"ç" [process-send-string get-buffer-process char-to-string read-char] 4 "\
  19. Send an arbitrary character to a program in shell mode." nil])
  20. (byte-code "└    ┬├#ê└    ─┼#ê└    ╞├#ç" [define-key shell-mode-map "" kermit-esc "" kermit-send-char "\\"] 4)
  21. (fset 'kermit-send-input-cr #[nil "└┴!ç" [comint-send-input ""] 2 "\
  22. Like \\[comint-send-input] but end the line with carriage-return." nil])
  23. (define-key shell-mode-map "\n" 'kermit-send-input-cr)
  24. (fset 'kermit-default-cr #[nil "└    ┬├#ê└    ─┼#ç" [define-key shell-mode-map "" kermit-send-input-cr "\n" comint-send-input] 4 "\
  25. Make RETURN end the line with carriage-return and LFD end it with a newline.
  26. This is useful for talking to other systems on which carriage-return
  27. is the normal way to end a line." nil])
  28. (fset 'kermit-default-nl #[nil "└    ┬├#ê└    ─┼#ç" [define-key shell-mode-map "\n" kermit-send-input-cr "" comint-send-input] 4 "\
  29. Make RETURN end the line with a newline char.  This is the default state.
  30. In this state, use LFD to send a line and end it with a carriage-return." nil])
  31. (fset 'kermit-clean-filter #[(proc str) "è└    !├    !qê\nbê─!ê╞╟\n╚#¡å╔╩!ê¬s*ç" [process-mark proc beg process-buffer insert-before-markers str re-search-backware "[]+" t replace-match ""] 4 "\
  32. Strip ^M and ^@ characters from process output."])
  33. (fset 'kermit-clean-on #[nil "└┴p!┬\"ç" [set-process-filter get-buffer-process kermit-clean-filter] 3 "\
  34. Delete all null characters and ^M's from the kermit output.
  35. Note that another (perhaps better) way to do this is to use the
  36. command `kermit | tr -d '\\015''." nil])
  37. (fset 'kermit-clean-off #[nil "└┴p!┬\"ç" [set-process-filter get-buffer-process nil] 3 "\
  38. Cancel a previous kermit-clean-shell-on command." nil])
  39.